package com.atguigu.gulimall.search.feign;

import com.atguigu.common.utils.R;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;

/**
 * @author zhuguanming
 * @description product服务Feign
 * @date 2021/6/4 22:26
 */
@FeignClient("gulimall-product")
public interface ProductFeignService {

    @RequestMapping("/product/attr/info/{attrId}")
    R info(@PathVariable("attrId") Long attrId);

    @RequestMapping("/product/brand/list/byIds")
    R listByIds(@RequestParam("catalogIds") List<Long> catelogIds);

    @RequestMapping("/product/category/info/{catId}")
    R catalogInfo(@PathVariable("catId") Long catId);
}
